<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="../assets/css/base.css">
</head>
<body>
    <div id="app">
        <pre v-pre class="note">
        vue的应用方法:createApp 构建的应用对象可以直接访问和调用的方法，被叫做应用方法
            + mount：将应用挂载到一个容器元素上，并返回vue实例对象。
            + unmount：卸载应用实例对应的容器元素
            + version：返回vue的版本
        </pre>
        <input type="button" value="printApp对象" @click="printApp()">
        <input type="button" value="unmountApp" @click="unmountApp()">
        <input type="button" value="printVueVersion" @click="printVueVersion()">

    </div>
    <script type="module">
        import { createApp } from "../assets/vue3/vue.esm-browser.js";
        const app = createApp({
            data() {
                return {
                    
                }
            },
            methods: {
                printApp() {
                    console.log(app)
                },
                unmountApp(){
                    app.unmount()
                },
                printVueVersion(){
                    console.log(app.version)
                }
            },
        })
        
        const vm = app.mount("#app")
    </script>
</body>
</html>